import request from '@/utils/request';

export async function getDetail(params) {
  return request(`/osApi/insDeduDet/insDeduDetInfo`, {
    method: 'POST',
    body: params,
  });
}
export async function getInsInfor(params) {
  return request(`/osApi/insDeduDet/getInsDeduDetInfo`, {
    method: 'POST',
    body: params,
  });
}
export async function updateInsData(params) {
  return request(`/osApi/insDeduDet/updateInsDeduDet`, {
    method: 'POST',
    body: params,
  });
}
export async function bigwarehouseData(params) {
  return request(`/osApi/insDeduDet/getInsAcco`, {
    method: 'POST',
    body: params,
  });
}

export async function getSocialReduce(params) {
  return request(`/osApi/insDeduDet/pageListInsDedu`, {
    method: 'POST',
    body: params,
  });
}

export async function getProList(params) {
  return request(`/osApi/problem/ins/pageList`, {
    method: 'POST',
    body: params,
  });
}

export async function getParam(params) {
  return request(`/osApi/operParam/getParam`, {
    method: 'POST',
    body: params,
  });
}

export async function getDic(params) {
  return request(`/osApi/insDeduDet/dictList`, {
    method: 'POST',
    body: params,
  });
}

export async function showConfirm(params) {
  return request(`/osApi/insDeduDet/syncInsDeduUnderLineDecl`, {
    method: 'POST',
    body: params,
  });
}

export async function underLineDecl(params) {
  return request(`/osApi/insDeduDet/syncInsDeduUnderLineDecl`, {
    method: 'POST',
    body: params,
  });
}

export async function cancleSign(params) {
  return request(`/osApi/insAddDet/signProbFlag`, {
    method: 'POST',
    body: params,
  });
}

export async function remarkOk(params) {
  return request(`/osApi/insDeduDet/addInsDeduRemark`, {
    method: 'POST',
    body: params,
  });
}

export async function getRemarkData(params) {
  return request(`/osApi/insDeduDet/listInsDeduRemark`, {
    method: 'POST',
    body: params,
  });
}

export async function addRemarkData(params) {
  return request(`/osApi/insDeduDet/addInsDeduRemark`, {
    method: 'POST',
    body: params,
  });
}

export async function signProbFlag(params) {
  return request(`/osApi/problem/ins/signProbFlag`, {
    method: 'POST',
    body: params,
  });
}

// export async function signSuccess(params) {
//   return request(`/osApi/insDeduDet/completeDecl`, {
//     method: 'POST',
//     body: params,
//   });
// }

export async function signSuccess(params) {
  return request(`/osApi/insDeduDetExt/completeDecl`, {
    method: 'POST',
    body: params,
  });
}

export async function declareOk(params) {
  return request(`/osApi/insAddDet/onLineDecl`, {
    method: 'POST',
    body: params,
  });
}

export async function onDeclare(params) {
  return request(`/osApi/insDeduDet/onLineDecl`, {
    method: 'POST',
    body: params,
  });
}

export async function onLineApply(params) {
  return request(`/osApi/insDeduDet/syncInsDeduOnLineDecl`, {
    method: 'POST',
    body: params,
  });
}

// export async function cancleApply(params) {
//   return request(`/osApi/insDeduDet/cancelDecl`, {
//     method: 'POST',
//     body: params,
//   });
// }

export async function cancleApply(params) {
  return request(`/osApi/insDeduDetExt/cancelDecl`, {
    method: 'POST',
    body: params,
  });
}

export async function signFail(params) {
  return request(`/osApi/insDeduDet/declFail`, {
    method: 'POST',
    body: params,
  });
}

export async function changeArea(params) {
  return request(`/osApi/mdm/nmArea/queryNmArea`, {
    method: 'POST',
    body: params,
  });
}

export async function getDeclList(params) {
  return request(`/osApi/insDeduDet/queryDeclDetInsDeduTemplate`, {
    method: 'POST',
    body: params,
  });
}
export async function getProgress(params) {
  return request(`/osApi/batchTask/getBatTaskInfo`, {
    method: 'POST',
    body: {
      ...params,
    },
  });
}

export async function problemGet(params) {
  return request(`/osApi/problem/ins/get`, {
    method: 'POST',
    body: params,
  });
}

export async function insertProbFdbk(params) {
  return request(`/osApi/problem/ins/insertProbFdbk`, {
    method: 'POST',
    body: params,
  });
}

export async function cancelProbFlag(params) {
  return request(`/osApi/problem/ins/cancelProbFlag`, {
    method: 'POST',
    body: params,
  });
}

export async function bmUploadFile(params) {
  return request(`/osApi/insDeduDet/insDeduBatchEdit`, {
    method: 'POST',
    body: params,
  });
}

export async function pUploadFile(params) {
  return request(`/osApi/insDeduDet/insDeduImport`, {
    method: 'POST',
    body: params,
  });
}
